<template>
  <div>
    <div id="container">

      <div id="header">
      </div>

    </div>
    <div id="container">
      <div id="content2">
        <table width="100%" height="41" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
            <td width="15" height="18" align="left" valign="top">
              <div align="left"></div>
            </td>
            <td width="385" align="left" valign="bottom" class="12">&nbsp;</td>
          </tr>
          <tr>
            <td height="4" colspan="2" align="left" valign="bottom"></td>
          </tr>
          <tr>
            <td height="15" align="left" valign="top">&nbsp;</td>
            <td height="15" align="left" valign="top" class="12">
              <table width="100%" height="20" border="0" cellpadding="0" cellspacing="0">
                <tr>
                  <td height="20" align="center">
                    <div class="right_proaducts">
                      <div align="left">我的位置&gt;&gt;科技项目申报&gt;项目查询</div>
                    </div>
                <tr>
                  <td valign="center" align="left" width="20%">
                    <h1>项目内容</h1>
                  </td>
                      <el-input v-model="search"></el-input>
                      <el-button @click="search()">查询</el-button>
                </tr>
                <DIV class=padding>
                  <DIV id=middlebody>

                    <el-table :data="user" :row-class-name="tableRowClassName">
                      <el-table-column label="主项目" prop="categoryname"></el-table-column>
                      <el-table-column label="分项目" prop="categoryname2"></el-table-column>
                      <el-table-column label="操作">
                        <template slot-scope="scope">
                          <el-row>
                            <el-button type="danger" @click="project(scope.row)"></el-button>
                          </el-row>
                        </template>
                      </el-table-column>
                    </el-table>
                    <div></div>
                  </DIV>
                </DIV>

            </td>
          </tr>
        </table>
        <br />
        <div class="table_wz"></div>
        </td>
        </tr>
        </table>
      </div>
    </div>


  </div>
</template>

<script>
import axios from '../../utils/Myaxios'

const options = {
  data() {
    return {
      search: '',
      user:[]
    }
  },
  methods: {
    async search() {
      const _axios = axios.create({
        baseURL: 'http://localhost:8080',
        withCredentials: true
      })
      const resp = await _axios.get('/units/search')
      this.user = resp.data.data
    }
  }
}
export default options
</script>

<style>

</style>